package com.zmn.oms.business.interfaces.work.orderpay;

import com.zmn.oms.common.dto.OmsOperator;
import com.zmn.oms.common.exception.OmsBaseException;
import com.zmn.oms.model.bo.refund.RefundInitiateBO;
import com.zmn.oms.model.dto.order.OrderDTO;
import com.zmn.oms.model.dto.work.modify.must.ZsOrderPayDTO;
import com.zmn.oms.model.entity.factory.OrderFactory;
import com.zmn.oms.model.entity.work.OrderWork;
import com.zmn.pay.gateway.common.model.dro.PayOrderDRO;
import lombok.Data;

/**
 * @author sunlife
 * @date:2021/1/21 4:54 下午
 * description:
 */
public interface FactoryAccountModifyBService {
    /**
     * 冻结金额
     */
    void freeze(OrderDTO orderDTO) throws OmsBaseException;
    /**
     * 解冻金额
     */
    void unFreeze(OrderWork orderWork, OrderFactory orderFactory,OmsOperator operator) throws OmsBaseException ;

    /**
     * 重新冻结并消费
     */
    PayOrderDRO consume(ZsOrderPayDTO payDTO) throws OmsBaseException;

    /**
     * 退款
     */
    void refund(RefundInitiateBO refundInitiateBO) throws OmsBaseException;

    /**
     * 退款
     */
//    void verifyFactoryFreezePermit(FactoryDRO factoryDRO, Integer amount, OmsOperator operator) throws OmsBaseException;
}
